package com.sfj.common.util;

import java.util.regex.Matcher;
import java.util.regex.Pattern;

/**
 * @author chengyangliu
 */
public class RegularUtils {

    public static Boolean regular(String value, String reg) {
        Pattern pattern = Pattern.compile(reg);
        Matcher matcher = pattern.matcher(value);
        boolean isEmailValid = matcher.matches();
        return isEmailValid;
    }
}
